/**
 * 
 */
package systole.persistence.brokersInterface;

import java.util.List;

import systole.domain.clinicalInformation.Surgery;
import systole.domain.clinicalInformation.SurgeryPatient;
import systole.domain.persons.Patient;
import systole.exceptions.ExceptionDAO;

/**
 * @author jmj
 * 
 */
public interface SurgeryByPatientBroker {

    /**
     * @param surgeryPatient
     * @throws ExceptionDAO
     */
    public void insert(SurgeryPatient surgeryPatient) throws ExceptionDAO;

    /**
     * @param surgeryPatient
     * @throws ExceptionDAO
     */
    public void update(SurgeryPatient surgeryPatient) throws ExceptionDAO;

    /**
     * @param surgeryPatient
     * @throws ExceptionDAO
     */
    public void delete(SurgeryPatient surgeryPatient) throws ExceptionDAO;

    /**
     * @param patient
     * @return all surgeries of a patient
     * @throws ExceptionDAO
     */
    public List<SurgeryPatient> getAllPatientSurgeries(Patient patient)
            throws ExceptionDAO;

    /**
     *
     * @param surgery
     * @param patient
     * @return if patient Surgery exist
     * @throws ExceptionDAO
     */
    public boolean existSurgeryByPatient(Surgery surgery, Patient patient)
            throws ExceptionDAO;
}
